package ReefStats::Schema::ReefStatsDB::ActionsReasonsAll;

use strict;
use warnings;

use base 'DBIx::Class';
use ReefStats::Schema::DataTypes;

=pod

+---------+-----------------------+------+-----+---------+-------+
| Field   | Type                  | Null | Key | Default | Extra |
+---------+-----------------------+------+-----+---------+-------+
| Day     | date                  | NO   | PRI | NULL    |       |
| Cluster | varchar(100)          | NO   | PRI | NULL    |       |
| Action  | varchar(100)          | NO   | PRI | NULL    |       |
| Reason  | varchar(100)          | NO   | PRI | NULL    |       |
| Number  | mediumint(8) unsigned | NO   |     | NULL    |       |
+---------+-----------------------+------+-----+---------+-------+

=cut

__PACKAGE__->load_components("Core");
__PACKAGE__->table("actions_reasons_all");
__PACKAGE__->add_columns(
    day     => { @_datetime,    @_not_null, @_default_nodate, },
    cluster => { @_varchar_100, @_not_null, },
    action  => { @_varchar_100, @_not_null, },
    reason  => { @_varchar_100, @_not_null, },
    number => { @_mediumint, @_not_null, extra => { @_unsigned, }, },
);

__PACKAGE__->set_primary_key(qw(day cluster action reason));

1;
